package day05;

import java.util.Scanner;

public class MainTest004 {
    public static void main(String[] args) {
        int[] num= {8,4,2,1,23,344,12};
        int sum = 0 ;
        for (int i = 0;i< num.length;i++){
            System.out.println(num[i]);
            sum+=num[i];
        }
        System.out.println("总数为："+sum);
        Scanner input = new Scanner(System.in);
        System.out.println("请输入一个数：");
        int num1 = input.nextInt();


    }


}
